import Mock from 'mockjs'
import url from 'url'

//负载趋势图像数据
const {LoadTrend_chart_List} = Mock.mock({
    'LoadTrend_chart_List': [
        {
            'id|+1': 1,
            'name': '@cword(2,4)',
            location: '@city(true)',
            data: '@integer(1000000,9999999)',
            day_ele: '@integer(1000000,9999999)',
            month_ele: '@integer(1000000,9999999)',
            year_ele: '@integer(1000000,9999999)',
            time: '@date(yyyy-MM-dd hh:mm:ss)'
        }
    ]
})

//电压趋势图像数据
const {VoltageTrend_chart_List} = Mock.mock({
    'VoltageTrend_chart_List': [
        {
            'id|+1': 1,
            'name': '@cword(2,4)',
            location: '@city(true)',
            data: '@integer(1000000,9999999)',
            day_ele: '@integer(1000000,9999999)',
            month_ele: '@integer(1000000,9999999)',
            year_ele: '@integer(1000000,9999999)',
            time: '@date(yyyy-MM-dd hh:mm:ss)'
        }
    ]
})

//电流趋势
const {CurrentTrend_chart_List} = Mock.mock({
    'CurrentTrend_chart_List': [
        {
            'id|+1': 1,
            'name': '@cword(2,4)',
            location: '@city(true)',
            data: '@integer(1000000,9999999)',
            day_ele: '@integer(1000000,9999999)',
            month_ele: '@integer(1000000,9999999)',
            year_ele: '@integer(1000000,9999999)',
            time: '@date(yyyy-MM-dd hh:mm:ss)'
        }
    ]
})
//水表耗水量趋势图像数据
const {WaterConsumption_chart_List} = Mock.mock({
    'WaterConsumption_chart_List': [
        {
            'id|+1': 1,
            'name': '@cword(2,4)',
            location: '@city(true)',
            data: '@integer(1000000,9999999)',
            day_ele: '@integer(1000000,9999999)',
            month_ele: '@integer(1000000,9999999)',
            year_ele: '@integer(1000000,9999999)',
            time: '@date(yyyy-MM-dd hh:mm:ss)'
        }
    ]
})

//有功功率趋势图像数据
const {ActivePower_chart_List} = Mock.mock({
    'ActivePower_chart_List': [
        {
            'id|+1': 1,
            'name': '@cword(2,4)',
            location: '@city(true)',
            data: '@integer(1000000,9999999)',
            day_ele: '@integer(1000000,9999999)',
            month_ele: '@integer(1000000,9999999)',
            year_ele: '@integer(1000000,9999999)',
            time: '@date(yyyy-MM-dd hh:mm:ss)'
        }
    ]
})



//负载趋势图像数据
Mock.mock('/api/module4/LoadTrend_chart','get',()=>{
    return {
        status: 200,
        message: '获取负载趋势信息成功',
        list: LoadTrend_chart_List,
    }
})

//电压趋势图像数据
Mock.mock('/api/module4/VoltageTrend_chart','get',()=>{
    return {
        status: 200,
        message: '获取负载趋势信息成功',
        list: VoltageTrend_chart_List,
    }
})

//电流趋势图像数据
Mock.mock('/api/module4/CurrentTrend_chart','get',()=>{
    return {
        status: 200,
        message: '获取负载趋势信息成功',
        list: CurrentTrend_chart_List,
    }
})

//水表耗水量趋势图像数据
Mock.mock('/api/module4/WaterConsumption_chart','get',()=>{
    return {
        status: 200,
        message: '获取负载趋势信息成功',
        list: WaterConsumption_chart_List,
    }
})

//有功功率趋势图像数据
Mock.mock('/api/module4/ActivePower_chart','get',()=>{
    return {
        status: 200,
        message: '获取负载趋势信息成功',
        list: ActivePower_chart_List,
    }
})
